package com.mapper;

import com.pojo.RoleInfo;
import org.mybatis.spring.SqlSessionTemplate;

import java.util.List;

public class RoleInfoMapperImpl implements RoleInfoMapper{

    private SqlSessionTemplate sqlSession;


    public void setSqlSession(SqlSessionTemplate sqlSession) {
        this.sqlSession = sqlSession;
    }

    @Override
    public List<RoleInfo> getRoleInfos() {
        RoleInfoMapper mapper=sqlSession.getMapper(RoleInfoMapper.class);
        return mapper.getRoleInfos();
    }

    @Override
    public List<RoleInfo> getRoleInfos2(int id) {
        RoleInfoMapper mapper=sqlSession.getMapper(RoleInfoMapper.class);
        return mapper.getRoleInfos2(id);
    }

}
